<?php 
$code = $this->uri->segment(1,0);
if($code=="0" || $code=="" || $code=="home#"){$code="home";}
?>
<div class="margin-top-10">
<table width="902" align="center" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td height="70" valign="middle"><a href="<?php echo base_url()?>">logo</a></td>
    <td align="right" id="nav-main" class="capitalize bold">
        <a href="<?php echo base_url();?>" class="<?php if($code=="home"){echo "active";}?>">home</a><span class="margin-10"></span>
        <a href="<?php echo base_url();?>berita" class="<?php if($code=="berita"){echo "active";}?>">about</a><span class="margin-10"></span>
        <a href="<?php echo base_url();?>info" class="<?php if($code=="info"){echo "active";}?>">event</a><span class="margin-10"></span>
        <a href="<?php echo base_url();?>info" class="<?php if($code=="info"){echo "active";}?>">event</a><span class="margin-10"></span>
        <?php
        if(get_cookie("logged")==true){
		?>
        	<a href="<?php echo base_url();?>my account" class="<?php if($code=="akun"){echo "active";}?>">Akun</a><span class="margin-10"></span>
        <?php } else {?>
        	<a href="<?php echo base_url();?>login" class="<?php if($code=="login"){echo "active";}?>">login</a><span class="margin-10"></span>
        <?php }?>
    </td>
  </tr>
</table>
</div>
<br />